/**
 * <pre>
 * Copyright 2008 Antonio Jacob Costa (jacob.costa@gmail.com)
 * 
 * Licensed under the Apache License, Version 2.0 (the &quot;License&quot;);
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at 
 * 
 *   http://www.apache.org/licenses/LICENSE-2.0
 * 
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an &quot;AS IS&quot; BASIS, 
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
 * See the License for the specific language governing permissions and 
 * limitations under the License.
 * </pre>
 */
package org.ajc.maximo4eclipse.templates;

import java.io.ByteArrayInputStream;
import java.io.InputStream;

/**
 * <p>
 * Generates the code for the MboRemote class.
 * </p>
 * TODO For now the code is hardcoded, the goal is to put it in template files.
 * 
 * @author Antonio Jacob Costa
 */
public class MboRemote {
  /**
   * <p>
   * We will initialize file contents with a sample text.
   * </p>
   */
  public static InputStream openContentStream(String mboName,
      String packageName, String superclassName) {
    String contents = "/*\n"
        + " * \n"
        + " */\n"
        + "package "+packageName+";\n"
        + "\n"
        + " /**\n"
        + " * Remote interface for the "+mboName+" Mbo.\n"
        + " *\n"
        + " * <p>\n"
        + " *   Class generated using maximo4eclipse\n"
        + " *   (http://code.google.com/p/maximo4eclipse/)\n"
        + " * </p>\n"
        + " *\n"
        + " */\n"
        + "public interface "+mboName+"Remote extends "+superclassName+"Remote {\n"
        + "}\n";
    return new ByteArrayInputStream(contents.getBytes());
  }
}
